package webidewar.system;

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 *
 * @author huy
 */
public abstract class CodeModifier {

    private int id;

    public abstract String convert(String _in);

    public void setId(int _id) {
        id = _id;
    }

    public int getId() {
        return id;
    }

    public static String stripHTML(String str){
        String re;
        re = str.replace("</p>", "\n");
        re = re.replace("<br>", "\n");
        re = re.replace("&nbsp;"," ");
        re = re.replace("&amp;", "&");
        re = re.replace("&gt;", ">");
        re = re.replace("&lt;", "<");
        re = re.replaceAll("\\<.*?>", "");
        return re;
    }
}
